package com.proba.annotations;

import com.proba.annotations.hibernate.HibernateDAOFactory;

public abstract class DAOFactory {

	private static final DAOFactory HIBERNATE = new HibernateDAOFactory();

	public static final DAOFactory DEFAULT = HIBERNATE;
	
    /**
     * Factory method for instantiation of concrete factories.
     */
    public static DAOFactory instance(Class factory) {
        try {
            return (DAOFactory)factory.newInstance();
        } catch (Exception ex) {
            throw new RuntimeException("Couldn't create DAOFactory: " + factory);
        }
    }
    
    public abstract PotrosenMaterijalDAO buildPotrosenMaterijalDAO();
    
    public abstract TipPotrosenMaterijalDAO buildTipPotrosenMaterijalDAO();
    
    public abstract SostojbaNaMaterijaliDAO buildSostojbaNaMaterijaliDAO();
	
	public abstract EdinicaMerkaDAO buildEdinicaMerkaDAO();
	
	public abstract GotovProizvodDAO buildGotovProizvodDAO();
	
	public abstract IsporacMaterObjektiDAO buildIsporacMaterObjektiDAO();
	
	public abstract IzvrsenaRealizacijaDAO buildIzvrsenaRealizacijaDAO();
	
	public abstract PartnerDAO buildPartnerDAO();
	
	public abstract ProizvodenPogonDAO buildProizvodenPogonDAO();
	
	public abstract ProizvodniMaterijaliDAO buildProizvodniMaterijaliDAO();
	
	public abstract RealizacijasevkupnoDAO buildRealizacijasevkupnoDAO();
	
	public abstract RecepturiBetonDAO buildRecepturiBetonDAO();
	
	public abstract SluzbaDAO buildSluzbaDAO();
	
	public abstract TipGotovProizvodDAO buildTipGotovProizvodDAO();
	
	public abstract TipPartnerDAO buildTipPartnerDAO();
	
	public abstract TipProizvodenPogonDAO buildTipProizvodenPogonDAO();
	
	public abstract TrebovanjeAsfaltDAO buildTrebovanjeAsfaltDAO();
	
	public abstract TrebovanjeBetonDAO buildTrebovanjeBetonDAO();
	
}
